package com.anolesoft.qxgl.service.employee.mapper;

import com.anolesoft.qxgl.dto.employee.EmployeeDto;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Update;

@Mapper
public interface EmployeeServiceMapper {
    /**
     * 修改密码
     * @param employeeDto
     * @return
     */
    @Update("update SYS_USER set PASSWORD = #{hashpw, jdbcType=VARCHAR} , MW = #{password, jdbcType=VARCHAR} where EMP_UID = #{empUid, jdbcType=VARCHAR}")
    int updatePassword(EmployeeDto employeeDto);


    /**
     * 重置密码
     * @param employeeDto
     * @return
     */
    @Update("update SYS_USER set PASSWORD = #{hashpw, jdbcType=VARCHAR} , MW = #{password, jdbcType=VARCHAR} where EMP_UID = #{objuid, jdbcType=VARCHAR}")
    int resetPassword(EmployeeDto employeeDto);

}
